<?php

/*
	This file is part of Mandragon.

    Mandragon is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    Mandragon is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with Mandragon.  If not, see <http://www.gnu.org/licenses/>.
*/

require_once 'PHPUnit/Framework.php';
require_once 'autoload.php';

class TestRegionManager extends PHPUnit_Framework_TestCase {

	function test_region_format() {
		$expected_region_name_1 = "region name 1";
		$expected_region_name_2 = "region name 2";

		$expected_region1 = array('name' => $expected_region_name_1);
		$expected_region2 = array('name' => $expected_region_name_2);
		$expected_regions = array($expected_region1, $expected_region2);

		$manager = new RegionManager();

		$actual = $manager->region_format($expected_regions);
		$this->assertEquals("$expected_region_name_2 > $expected_region_name_1", $actual);
	}
}


?>
